//
//  TimeClass.hpp
//  Practice11
//
//  Created by 赵世杰 on 2020/7/26.
//  Copyright © 2020 zhaoshijie. All rights reserved.
//

#ifndef TimeClass_hpp
#define TimeClass_hpp

#include <stdio.h>
#include <iostream>

#endif /* TimeClass_hpp */



class Time
{
private:
    int hours;
    int minutes;
public:
    Time();
    Time(int h,int m=0);
    void addMin(int m);
    void addHr(int h);
    void reset(int h=0, int m=0);
    Time operator+(const Time &t)const;
    Time operator-(const Time &t)const;
    Time operator*(double n)const;
    
    friend Time operator*(double m,const Time &t){return t*m;};
    
    friend std::ostream & operator << (std::ostream & os , const Time & t);
    
};
